/*
    Copyright (C) 2010-2011 AmigaVR
    
    This file is part of AmigaVR.
    Written by Ketfi-Chérif Mehdi <ketficherif.mehdi@gmail.com>,
	       Laügt Franz <znarf94@gmail.com>

    AmigaVR is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
    the Free Software Foundation, either version 3 of the License, or
    (at your option) any later version.

    AmigaVR is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with AmigaVR.  If not, see <http://www.gnu.org/licenses/>.

*/

#ifndef _STRUCT_H
#define _STRUCT_H

typedef struct _mod_sample
{
	char name[22];
	uint16_t length;
	uint8_t finetune;
	uint8_t volume;
	uint16_t repeat_offset;
	uint16_t repeat_length;
}mod_sample , *pmod_sample;

typedef struct _mod_file
{
	char buffer[MOD_BUFFER_MAX];
	char title[20];
	mod_sample sample[31];
	uint8_t npatterns;
	uint8_t jmp_end;
	uint8_t pattern[128];
	char tag[4];
	uint8_t npatterns_played;
	uint8_t speed;
	uint16_t cplay;
	uint16_t cbuf;
	uint8_t cbufr;
}mod_file , *pmod_file;

typedef struct _stream_t
{
	uint16_t buffer_cursor, play_cursor;
	uint8_t cursor_reset;
	uint8_t buffer[MAX_BUFFER];
}stream_t, *pstream_t;

#endif

